//
//  NetworkTools.swift
//  iOS07-Weibo-LPK
//
//  Created by 罗培克 on 6/26/15.
//  Copyright © 2015 lpk. All rights reserved.
//

import UIKit
import AFNetworking

class NetworkTools: AFHTTPSessionManager {
    private static let instance: NetworkTools = {
        let baseURL = NSURL(string: "https://api.weibo.com/")
        let tools = NetworkTools(baseURL: baseURL)
        tools.responseSerializer.acceptableContentTypes = NSSet(objects: "application/json", "text/json", "text/javascript", "text/plain") as! Set<String>
        
        return tools
    }()
    
    class func sharedNetworkTools() -> NetworkTools {
        return instance
    }
}
